Fix a memory leak (#515039, Christian Persch)
authorMatthias Clasen <mclasen@redhat.com>
Tue, 12 Feb 2008 15:38:47 +0000 (15:38 +0000)
committerMatthias Clasen <matthiasc@src.gnome.org>
Tue, 12 Feb 2008 15:38:47 +0000 (15:38 +0000)
2008-02-12  Matthias Clasen  <mclasen@redhat.com>

        * tests/prop-editor.c: Fix a memory leak (#515039, Christian Persch)

svn path=/trunk/; revision=19526

ChangeLog
tests/prop-editor.c

index df8984bef4d25fffa1a6a7c28c5b55826b30c239..3156157cdc5110b8597d6db1346f6bbb58ba63f0 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+2008-02-12  Matthias Clasen  <mclasen@redhat.com>
+
+       * tests/prop-editor.c: Fix a memory leak (#515039, Christian Persch)
+       
 2008-02-12  Matthias Clasen  <mclasen@redhat.com>
 
        * tests/testmerge.c: Fix a memory leak (#515038, Christian Persch)
index 22f6ad2fd6405b3a1c010f6466fbac9d3c2165b4..442b162e9bbc9480235faa9a73d94ecc4bb2ffb0 100644 (file)
@@ -919,8 +919,10 @@ properties_from_type (GObject     *object,
       specs = g_object_class_list_properties (class, &n_specs);
     }
         
-  if (n_specs == 0)
+  if (n_specs == 0) {
+    g_free (specs);
     return NULL;
+  }
   
   table = gtk_table_new (n_specs, 2, FALSE);
   gtk_table_set_col_spacing (GTK_TABLE (table), 0, 10);